package com.adtec.yxdemo.filelanding.service;

import com.adtec.yxdemo.datascraping.entity.po.YxDetails;
import com.adtec.yxdemo.datascraping.entity.po.YxOrderDetails;
import com.adtec.yxdemo.datascraping.entity.po.YxPayInfo;
import com.adtec.yxdemo.datascraping.entity.po.YxPayTrack;
import com.adtec.yxdemo.datascraping.service.base.BaseYxDetailsService;
import com.adtec.yxdemo.datascraping.service.base.BaseYxOrderDetailsService;
import com.adtec.yxdemo.datascraping.service.base.BaseYxPayInfoService;
import com.adtec.yxdemo.datascraping.service.base.BaseYxPayTrackService;
import com.jfinal.aop.Inject;
import com.jfinal.plugin.activerecord.Db;
import com.jfinal.plugin.activerecord.Record;

import java.util.List;

public class SelectDbService {
    @Inject
    BaseYxPayInfoService baseYxPayInfoService;
    @Inject
    BaseYxOrderDetailsService baseYxOrderDetailsService;
    @Inject
    BaseYxDetailsService baseYxDetailsService;
    @Inject
    BaseYxPayTrackService baseYxPayTrackService;

    /**
     * account 信息表
     * @return
     */
    public List<Record> getAccountInfo(){
        return Db.findAll("yx_user_info");
    }
    /**
     * payinfo 信息表
     * @return
     */
    public List<Record> getPayInfos(){
        return Db.findAll("yx_pay_info");
    }

    /**
     * yxOrderDetails 信息表
     * @return
     */
    public List<Record> getOrderDetails(){
       return Db.findAll("yx_order_details");
    }

    /**
     * yxDetails 信息表
     * @return
     */
    public List<Record> getDetails(){
        return Db.findAll("yx_details");
    }

    /**
     * yxPayTrack 信息表
     * @return
     */
    public List<Record> getPayTracks(){
        return Db.findAll("yx_pay_track");
    }
}
